class TFBanner extends TFPowerups;

var tfCommanderFlagRed flag;

replication
{
    reliable if ( Role == ROLE_Authority )
		flag;
}

state Activated
{
	function BeginState()
	{
        initialstate='activated';
        if(instigator==none) instigator=pawn(owner);
        Owner.PlaySound(ActivateSound,SLOT_Interface,4);
        bActive = true;

        if(instigator.PlayerReplicationInfo.team.TeamIndex==0) flag=spawn(class'taskforces.tfcommanderflagred');
        else flag=spawn(class'taskforces.tfcommanderflagblue');

        flag.SetHolder(instigator.Controller);
    }

	function EndState()
	{
        if(flag!=none) flag.destroy();
        bActive = false;
	}

    function Timer()
    {

    }

	function Activate()
	{

	}
}

defaultproperties
{
     bAutoActivate=True
     bActivatable=True
     ActivateSound=Sound'GameSounds.Fanfares.UT2K3Fanfare11'
     bReplicateInstigator=True
     SkillCost=100
}
